// app.js
App({
  globalData: {},
  onLaunch(){
    //读取本地存储的token
    this.getoken()
  },
  getoken(){
   this.token=wx.getStorageSync('token')
   //读取本地数据
   this.refreshToken=wx.getStorageSync('refreshToken')
  },
  setToken(key,token){
    //因为是变量所以放在数组中
    this[key]=token
    //将token存入本地
   wx.setStorageSync(key,token)
  }
})
import './utils/http'
import './utils/utils'